import { createStore } from 'vuex'

export default createStore({
  state: {
    isShowLoginBox: false,
    userInfo:{}
  },
  mutations: {
    showLogin(state, isShow){
      state.isShowLoginBox = isShow
    },
    updateUserInfo(state, userData){
      state.userInfo = userData
    },
    updateUserName(state, user){
      state.userInfo.user = user
    }
  },
  actions: {
  },
  modules: {
  }
})
